package com.itheima.d10_bufferedreader;

import java.io.BufferedReader;
import java.io.FileReader;

/**
 * 缓冲字符流 BufferedReader 读取文件
 */
public class BufferedReaderDemo1 {
    public static void main(String[] args) {
        try(
                FileReader fr = new FileReader("day06-file-io\\src\\test03.txt");
                BufferedReader br = new BufferedReader(fr);
                ){
//            System.out.println(br.readLine());
//            System.out.println(br.readLine());
//            System.out.println(br.readLine());
//            System.out.println(br.readLine());
//            System.out.println(br.readLine());
//            System.out.println(br.readLine());
//            System.out.println(br.readLine());
            String line;
            while((line = br.readLine()) != null){
                System.out.println(line);
            }
        }catch (Exception e){
            e.printStackTrace();
        }

    }
}
